package com.qqtech.qquan.user.model;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import com.qqtech.core.common.util.TimeUtil;

@SuppressWarnings("serial")
public class UserDrawVo extends UserDraw {
	private boolean hasImg;

	private String couponStatus;
	
	private String hour;
	
	public String getHour() {
		return hour;
	}

	public void setHour(String hour) {
		this.hour = hour;
	}

	private String drawItemImg;

	private String userNick;
	
	/**抽奖名称**/
	private String drawBaseName;
	
	/**
	 * 社区
	 */
	private String communityName;
	
	public String getCommunityName() {
		return communityName;
	}

	public void setCommunityName(String communityName) {
		this.communityName = communityName;
	}

	public String getCouponStatus() {
		return couponStatus;
	}

	public String getDrawItemImg() {
		return drawItemImg;
	}

	public String getStatusStr() {
		if (null == this.getStatus()) {
			return null;
		}
		if (this.getStatus().intValue() == 1) {
			return "已领取";
		} else if (this.getStatus().intValue() == 2) {
			return "未领取";
		} else {
			return "已失效";
		}
	}

	public String getStrNewAt() {
		return TimeUtil.getStringTimeByFormat(getNewAt(), "yyyy-MM-dd HH:mm");
	}

	public String getStrUpdAt() {
		return TimeUtil.getStringTimeByFormat(getUpdAt(), "yyyy-MM-dd HH:mm");
	}

	public String getUserNick() {
		return userNick;
	}

	public boolean isHasImg() {
		return hasImg;
	}

	public void setCouponStatus(String couponStatus) {
		this.couponStatus = couponStatus;
	}

	public void setDrawItemImg(String drawItemImg) {
		this.drawItemImg = drawItemImg;
	}

	public void setHasImg(boolean hasImg) {
		this.hasImg = hasImg;
	}

	public void setUserNick(String userNick) {
		this.userNick = userNick;
	}

	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this, ToStringStyle.MULTI_LINE_STYLE);
	}

	public String getDrawBaseName() {
		return drawBaseName;
	}

	public void setDrawBaseName(String drawBaseName) {
		this.drawBaseName = drawBaseName;
	}
}